<?php
//对多个字符串键名相同的 ,进行合并,后面的抛弃
$array1 = array(3, "color" => "red", 2);
$array2 = array(3, "a", "b", "color" => "green", "shape" => "trapezoid");
var_dump($array1);
var_dump($array2);
$result = array_merge($array1, $array2);
print_r($result);

$ar1 = array('A'=>4,"color" => array("favorite" => "red"), 5);
$ar2 = array('A'=>5,10, "color" => array("favorite" => "green", "blue"));
$result = array_merge($ar1, $ar2);
print_r($result);
